<template>
    <div class="div">
        &nbsp;&nbsp;人员信息
    </div>
    <table id="person" cellspacing="0" style="width: 100%;height: 50px;border: 1px solid #a8aeb2;">
        <tr class="tr" v-for="pers in labRecordPerList">
            <th v-for="per in pers.itemsRecordPersonList" class="thE" :rowspan="per.fieldRowspan > 0 ? per.fieldRowspan : 1"  :colspan="per.fieldColspan > 0 ? per.fieldColspan : 1">
                <span v-if="per.fieldInput === '0'">{{ per.fieldName }}</span>
                <a-input :name="per.fieldCode" v-else-if="per.fieldInput === '1' && per.fieldCode === 'check_person'"  readonly="true" v-model:value="per.fieldValue" size="large" class="input"  />
                <a-input :name="per.fieldCode" v-else-if="per.fieldInput === '1' && per.fieldCode === 'audit_person'" :value="per.fieldValue" size="large" class="input"  readonly="true"/>
            </th>
        </tr>
    </table>

</template>
  
<script lang="ts" setup>
import { reactive } from 'vue';





const props = defineProps<{
    labRecordPerList: [{
        pId: String | number,
        itemsRecordPersonList: [{
            id: String | number,
            createBy: String,
            createTime: String,
            updateBy: String,
            updateTime: String,
            sysOrgCode: String,
            taskId: String,
            itemId: String,
            fieldName: String,
            fieldCode: String,
            fieldValue: String,
            fieldInput: String | number,
            fieldSort: number,
            fieldType: String,
            fieldRow: number,
            fieldCol: number,
            fieldRowspan: number,
            fieldColspan: number,
        }]
    }],
}>();

const formPerData = reactive<Record<string, any>>({
    auditId: "",
    auditName: "",
});


defineExpose({
    props,
    formPerData
});



</script>
  
<style scoped>
.div {
    height: 45px;
    border: 1px solid #a8aeb2;
    background-color: #d2d5d6;
    text-align: left;
    font: 1.2em sans-serif;
    line-height: 45px
}

.tr {
    height: 50px;
    border: 1px solid #a8aeb2;
}

.thE {
    width: 25%;
    text-align: center;
    border: 1px solid #a8aeb2;
    font: 1.2em sans-serif;
}

.input {
    width: 100%;
    height: 100%;
    border: none;
    background-color: inherit;
    outline: none;
    border-bottom: none;
}</style>